# 导入必要的包
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
# 设置中文字体
plt.rcParams['font.sans-serif'] = ['SimHei']
plt.rcParams['axes.unicode_minus'] = False

# 示例数据
regions = ['Region1', 'Region2', 'Region3']
metrics = ['temperature', 'rainfall', 'pressure', 'wind_speed', 'dew_point']
historical_data = np.random.normal(loc=20, scale=5, size=(len(regions), len(metrics)))
predicted_data = np.random.normal(loc=22, scale=5, size=(len(regions), len(metrics)))
# 温度 降雨 气压 风速
data = {}
for i, metric in enumerate(metrics):
    data[f'historical_{metric}'] = historical_data[:, i]
    data[f'predicted_{metric}'] = predicted_data[:, i]
data['region'] = regions
df = pd.DataFrame(data).set_index('region')

# 打印表格
print("综合气象数据对比表格（含预测）:")
print(df)